// router/index.js

import Vue from 'vue'
import modules from './router'
//这里仅示范npm安装方式的引入，其它方式引入请看最上面【安装】部分
// import Router from 'uni-simple-router'
import Router,{ RouterMount } from 'uni-simple-router'

// import routerLink from 'uni-simple-router/component/router-link'
// Vue.component('router-link',routerLink)

Vue.use(Router)
//初始化
const router = new Router({
	// encodeURI:false,  
  routes: [...modules]//路由表
});

//全局路由前置守卫
router.beforeEach((to, from, next) => {
  next()
})

// 全局路由后置守卫
router.afterEach((to, from) => {
	
})
// export default router;
export default RouterMount;